package com.zbkj.service.service;

import com.sun.org.apache.xpath.internal.operations.Bool;
import com.zbkj.common.netty.AcceptDataContent;
import io.netty.channel.Channel;
import io.netty.channel.ChannelHandlerContext;

public interface SendMessageService {

    /**
     * 客服聊天登录
     * 示例：{"messageType":0,"extendField":"user:normal:d63b882cdde14fffaf7c58893a5c0829"}
     * @param acceptDataContent
     * @return 是否绑定成功
     */
    Boolean login(AcceptDataContent acceptDataContent, Channel channel);
    void logout(Channel channel);

    /**
     * 转发消息
     * 会经过redis
     * @param acceptDataContent
     */
    void sendMessage(AcceptDataContent acceptDataContent);

    /**
     * 对这个 channel 直接发送消息
     * @param acceptDataContent
     * @param channel
     */
    void sendMessage(AcceptDataContent acceptDataContent, Channel channel);
}
